package dao

import "gorm.io/gorm"

type User struct {
	gorm.Model
	UserName  string `gorm:"type:varchar(30);not null;comment:'用户名'"`
	NickName  string `gorm:"type:varchar(30);not null;comment:'昵称'"`
	HeadImage string `gorm:"type:varchar(255);not null;comment:'头像'"`
	Intro     string `gorm:"type:varchar(255);not null;comment:'签名'"`
}
type Friend struct {
	gorm.Model
	UserId    int    `gorm:"type:int(11);not null;comment:'用户id'"`
	FriendId  int    `gorm:"type:int(11);not null;comment:'好友id'"`
	UserName  string `gorm:"type:varchar(30);not null;comment:'用户名'"`
	NickName  string `gorm:"type:varchar(30);not null;comment:'昵称'"`
	HeadImage string `gorm:"type:varchar(255);not null;comment:'头像'"`
	Intro     string `gorm:"type:varchar(255);not null;comment:'签名'"`
}
type Message struct {
	gorm.Model
	UserId   int    `gorm:"type:int(11);not null;comment:'用户id'"`
	FriendId int    `gorm:"type:int(11);not null;comment:'好友id'"`
	Content  string `gorm:"type:varchar(255);not null;comment:'消息内容'"`
	Status   int8   `gorm:"type:tinyint;default:0;comment:'消息状态:0-未读,1-已读'"`
}
